import axios from './axios'
import base from "./base";
const api = {
    login(data) {
        return axios({
            url: '/user/weblogin',
            data,
            method: 'post'
        })
    },
    getUSerInfo(data) {
        return axios({
            url: '/user/getUSerInfo',
            method: 'get'
        })
    },
    userlist(data) {
        return axios({
            url: '/user/list?size=10&page=1&type=1',
            method: 'get'
        })
    },
    shoucang(data) {
        return axios({
            url: '/dingcai/shoucang',
            method: 'get',
            params:data
        })
    },
    orderchangeStatus(params) {
        return axios({
            url: '/order/changeStatus',
            method: 'get',
            params
        })
    },
    videolist(params) {
        return axios({
            url: '/video/list',
            method: 'get',
            params
        })
    },
    xiaoliang(params) {
        return axios({
            url: '/product/xiaoliang',
            method: 'get',
            params
        })
    },
    orderupdate(params) {
        return axios({
            url: '/order/update',
            method: 'get',
            params
        })
    },
    addCart(data) {
        return axios({
            url: '/cart/add',
            data,
            method: 'post'
        })
    },
    updateCart(data) {
        return axios({
            url: '/cart/update',
            data,
            method: 'post'
        })
    },
    addOrder(data) {
        return axios({
            url: '/order/add',
            data,
            method: 'post'
        })
    },
    listOrder(data) {
        return axios({
            url: '/order/list',
            params: data,
            method: 'get'
        })
    },
    timulist(data) {
        return axios({
            url: '/system/timu/list',
            params: data,
            method: 'get'
        })
    },
    udaanadd(data) {
        return axios({
            url: '/system/udaan/add',
            data: data,
            method: 'post'
        })
    },
    getTuijian(data) {
        return axios({
            url: '/video/getTuijian',
            params: data,
            method: 'get'
        })
    },
    gettyperList(params) {
        return axios({
            url: '/type/list',
            method: 'get',
            params
        })
    },
    getCartById(params) {
        return axios({
            url: '/cart/list',
            method: 'get',
            params
        })
    },
    deleteCart(id) {
        return axios({
            url: '/cart/delete/' + id,
            method: 'get',
        })
    },
    getproductList(data) {
        return axios({
            url: '/product/list',
            method: 'get',
            params: data
        })
    },
    getfenleiList(data) {
        return axios({
            url: '/fenlei/list',
            method: 'get',
            params: data
        })
    },
    getpinglunList(data) {
        return axios({
            url: '/pinglun/list',
            method: 'get',
            params: data
        })
    },
    addPinglun(data) {
        return axios({
            url: '/pinglun/add',
            method: 'post',
            data
        })
    },
    getProductById(params) {
        return axios({
            url: '/video/getDetail',
            method: 'get',params
        })
    },
    dingcairemove(params) {
        return axios({
            url: '/dingcai/remove',
            method: 'get',params
        })
    },
    dingcailist(params) {
        return axios({
            url: '/dingcai/list',
            method: 'get',params
        })
    },
    dingcaiadd(params) {
        return axios({
            url: '/dingcai/add',
            method: 'get',params
        })
    },
    deleteDizhi(id) {
        return axios({
            url: '/dizhi/delete/' + id,
            method: 'get',
        })
    },
    dizhiList(params) {
        return axios({
            url: '/dizhi/list',
            method: 'get',
            params
        })
    },
    addDizhi(data) {
        return axios({
            url: '/dizhi/add',
            method: 'post',
            data
        })
    }

};
export default api;